package com.huayousoft.demo.order.feign;

import com.huayousoft.demo.order.entity.Goods;
import com.huayousoft.demo.order.feign.fallback.GoodsFeignClientFallback;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;

import java.util.List;

/**
 * 远程调用Goods的服务（feign）
 *
 * @author ZhangHua
 * @date 2020/11/20 13:46
 */
@FeignClient(name = "goods-service",fallback = GoodsFeignClientFallback.class)
public interface GoodsFeignClient {

    @GetMapping("/goods/list")
    public List<Goods> list();

}
